<?php
/**
 * Inspired from
 * http://github.com/weierophinney/pastebin/blob/b796ad0e5905e46b312a5b904a2a80c3ed8ff808/tests/TestHelper.php
 */

/**
 * Flag
 */
define('BOOTSTRAP_LOADED', true);

/*
* Start output buffering
*/
ob_start();
 
/*
* Set error reporting to the level to which Zend Framework code must comply.
*/
error_reporting( E_ALL | E_STRICT );
 
/*
* Maximize memory limit
*/
ini_set('memory_limit', -1);
 
/*
* Set default timezone
*/
date_default_timezone_set('GMT');
 
/*
* Determine the root, library, tests, and models directories
*/
$root = realpath(dirname(__FILE__) . '/../');
$library = $root . '/../library';
$tests = $root . '/library';

/*
* Prepend the library/, tests/, and models/ directories to the
* include_path. This allows the tests to run out of the box.
*/
$path = array(
    $library,
    $tests,
    get_include_path()
);
set_include_path(implode(PATH_SEPARATOR, $path));
 
/**
* Register autoloader
*/
require_once 'Zend/Loader/Autoloader.php';
Zend_Loader_Autoloader::getInstance()->registerNamespace(array('Oolala_'));
 
/*
* Unset global variables that are no longer needed.
*/
unset($root, $library, $tests, $path);